package com.webapp.domain.entity;

import java.util.Date;

import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.OneToOne;

import com.alibaba.fastjson.annotation.JSONField;
/*
 * 网上调解对接状态表
 */
@Entity
public class Mediation extends BaseEntity{

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	
	private long id;
	private String code;
	private Disputes disputes;
//	private String mediationId; //网上调解id 待定
	private Date createTime;
	@Id
	@GeneratedValue(strategy=GenerationType.AUTO)
	public long getId() {
		return id;
	}
	public void setId(long id) {
		this.id = id;
	}
	public String getCode() {
		return code;
	}
	public void setCode(String code) {
		this.code = code;
	}
	
	@OneToOne(mappedBy = "mediation", fetch=FetchType.LAZY,cascade=CascadeType.ALL)
	@JSONField(serialize=false)
	public Disputes getDisputes() {
		return disputes;
	}
	public void setDisputes(Disputes disputes) {
		this.disputes = disputes;
	}
	public Date getCreateTime() {
		return createTime;
	}
	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}
	

	
	
}
